import React from 'react';

import BaseAction from '../common/BaseAction';
import Constants from '../../common/Constants';

export default class QZ_ApplyAction extends BaseAction{
  constructor() {
    super();

    this.moduleType = Constants.MODULE_TYPE.QUAN_ZI;
    this.name = "QZ_ApplyAction";
  }

  call(caller, data) {
    this._baseCall(caller, data);
    this.caller.setState({
      viewStatus: 2,
    })
  }

  finish(data, isSucceed) {
    if(isSucceed) {
      viewStatus = 3;
    }
    else {
      viewStatus = 4;
    }
    this.caller.setState({
      isResponeUpdate: true,
      viewStatus: viewStatus,
    })
  }
}
